apiready = function() {
    seajs.use(['../../V', "../../api", "../../jquery", "../../app", "../../service", "../../swiper"], function(V, $api, $, $app, service, swiper) {
        var vm = {
            el: '.container',
            data: {
                is_group: false,
                order_id: '',
                name: ''
            },
            methods: {
                //--立即评价
                openComment: function(et) {
                    $app.openWin('buyCommentList', {
                        order_id: this.order_id,
                        is_group: this.is_group,
                        name: this.name
                    });
                },
                //--个人中心
                openMyperson: function(et) {
                    $app.openWin('buyPerson');
                }
            },
            mounted: function() {
                var self = this;

                function btnKeyBack() {
                    api.sendEvent({
                        name: 'orderInit_',
                    });
                    $api.setTimeout(function() {
                        api.closeToWin({
                            name: self.name
                        });
                    }, 300);
                }
                //--点击上面按钮返回
                $api.addEvt($api.dom('#btn-back-new'), 'click', function() {
                    btnKeyBack();
                });

                //--返回键
                api.addEventListener({
                    name: 'keyback'
                }, function(ret, err) {
                    btnKeyBack();
                });
                //--右滑
                api.addEventListener({
                    name: 'swiperight'
                }, function(ret, err) {
                    btnKeyBack();
                });
            },
            created: function() {
                this.is_group = api.pageParam.is_group;
                this.order_id = api.pageParam.order_id;
                this.name = api.pageParam.name || api.pageParam.prve;
            }
        };
        //var shopVue = new Vue(vm);
        var even = function() {

        };
        var newVue = new Vue(vm);
        even();

    })
}
